package model.dto;

import model.enums.UserStatusType;

public class UserDTO {
	private Integer id;
	private String ip;
	private UserStatusType status;

	public UserDTO(){
		this.id=0;
		this.ip="";
		this.status=UserStatusType.OFFLINE;
	}

	public UserDTO(Integer id){
		this.id=id;
		this.ip="";
		this.status=UserStatusType.OFFLINE;
	}

	public UserDTO(Integer id, String ip, UserStatusType status){
		this.id=id;
		this.ip=ip;
		this.status=status;
	}

	public Integer getId() {
		return id;
	}
	public void setId(Integer id) {
		this.id = id;
	}
	public String getIp() {
		return ip;
	}
	public void setIp(String ip) {
		this.ip = ip;
	}

	public String toString(){
		StringBuffer strBuf=new StringBuffer();
		strBuf.append("<id>");
		strBuf.append(this.id);
		strBuf.append("</id>");
		strBuf.append("<ip>");
		strBuf.append(this.ip);
		strBuf.append("</ip>");
		strBuf.append("<status>");
		strBuf.append(this.status.toString());
		strBuf.append("</status>");
		return strBuf.toString();
	}

	public UserStatusType getStatus() {
		return status;
	}

	public void setStatus(UserStatusType status) {
		this.status = status;
	}
}
